<form class="layui-form layui-card" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
    <div class="layui-card-body padding-left-40">

        <fieldset class="layui-form-item">
            <legend>用户资料</legend>
            <div class="layui-row layui-col-space15">
                <div class="layui-col-xs3">
                    <div class="layui-table">
                        <div class="headimg WechatUserHead" data-tips-image data-lazy-src="{$user.headimg|default='__ROOT__/static/theme/img/headimg.png'}"></div>
                    </div>
                </div>
                <div class="layui-col-xs9">
                    <label class="layui-form-item relative block">
                        <span class="color-green font-w7">微信昵称</span>
                        <span class="color-desc margin-left-5">Wechat Nickname</span>
                        <input data-bind="nickname" class="layui-input layui-bg-gray" readonly required placeholder="请使用微信扫码登录" value="{$user.nickname|default=''}"/>
                    </label>
                    <label class="relative block">
                        <span class="color-green font-w7">微信标识</span>
                        <span class="color-desc margin-left-5">Wechat Openid</span>
                        <input data-bind="openid" class="layui-input layui-bg-gray" readonly required placeholder="请使用微信扫码登录" value="{$user['openid1']?:($user['openid2'])}"/>
                    </label>
                </div>
            </div>
        </fieldset>

        <label class="layui-form-item relative block">
            <span class="color-green font-w7">充值单号</span>
            <span class="color-desc margin-left-5">Code</span>
            <input class="layui-input layui-bg-gray" readonly required placeholder="请输入充值单号" name="name" value="{$vo.code|default=''}"/>
        </label>

        <label class="layui-form-item relative block">
            <span class="color-green font-w7">充值名称</span>
            <span class="color-desc margin-left-5">Name</span>
            <input class="layui-input" required placeholder="请输入充值名称" name="name" value="{$vo.name|default='后台充值'}"/>
        </label>

        <label class="layui-form-item relative block">
            <span class="color-green font-w7">充值金额</span>
            <span class="color-desc margin-left-5">Amount</span>
            <input class="layui-input" data-blur-number="2" required placeholder="请输入充值金额" name="amount" value="{$vo.amount|default='0.00'}"/>
        </label>

        <div class="layui-form-item relative block">
            <span class="color-green font-w7">充值备注</span>
            <span class="color-desc margin-left-5">Remark</span>
            <label class="relative block">
                <textarea class="layui-textarea" placeholder="请输入充值备注" name="remark">{$vo.remark|default=''}</textarea>
            </label>
        </div>

    </div>

    <div class="hr-line-dashed"></div>
    <input type='hidden' value='{$vo.uid|default=$user.id}' name='uid'>
    {notempty name='vo.id'}<input type='hidden' value='{$vo.id}' name='id'>{/notempty}

    <div class="layui-form-item text-center">
        <button class="layui-btn" type='submit'>保存数据</button>
        <button class="layui-btn layui-btn-danger" type='button' data-confirm="确定要取消编辑吗？" data-close>取消编辑</button>
    </div>
</form>

<style>
    .WechatUserHead {
        width: 138px !important;
        height: 138px !important;
    }
</style>